home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Hráč 2004 August
/
Hrac_72_2004-08_dvd.iso
/
dema
/
Rapid Gun
/
rg_setup.exe
/
common
/
cdiffuse.fx
< prev
next >
Wrap
Text File
|
2004-04-19
|
2KB
|
78 lines
// LF2 Engine
// (C) 2002-3 7FX
//---------------------------------------------------------------------------
#include "basic_vs.fxh"
//---------------------------------------------------------------------------
// Effect for rendering colored objects
//---------------------------------------------------------------------------
// Common parameters
// Desc
string desc : Description = "Shader pro objekty, ktere se budou kreslit konstantni barvou";
// Requirements
string req : Requirements = "Diffuse";
// vertex format
string vf : VertexFormat = "POSITION";
//---------------------------------------------------------------------------
const int cAlphaRef : AlphaRef = 0;
// Line diffuse color, default white
const float4 cColor : Diffuse = {1.f, 1.f, 1.f, 1.f};
// CullMode - NONE=1, CW=2, CCW=3
const int cCullMode : CullMode = 3; // default CCW
// Matrices for fixed function technique
const matrix cMtxW : World;
//---------------------------------------------------------------------------
//! Techniques
technique vs11_ps0
<
// streams for technique
string stream1 = "POSITION";
>
{
pass p0
<
// stream mapping
string streammap = "stream1";
>
{
VertexShader = <cBasicVS>; // use shared basic vertex shader
AlphaRef = <cAlphaRef>;
CullMode = <cCullMode>;
TextureFactor = <cColor>;
ColorOp[0] = SelectArg1;
ColorArg1[0] = TFactor;
AlphaOp[0] = SelectArg1;
AlphaArg1[0] = TFactor;
}
}
//---------------------------------------------------------------------------
//! Techniques
technique vs0_ps0
<
// streams for technique
string stream1 = "POSITION";
>
{
pass p0
<
// stream mapping
string streammap = "stream1";
>
{
// matrices
WorldTransform[0] = <cMtxW>;
AlphaRef = <cAlphaRef>;
CullMode = <cCullMode>;
TextureFactor = <cColor>;
ColorOp[0] = SelectArg1;
ColorArg1[0] = TFactor;
AlphaOp[0] = SelectArg1;
AlphaArg1[0] = TFactor;
}
}
//---------------------------------------------------------------------------